import java.io.File;
import java.io.IOException;

/**
 * Created with IntelliJ IDEA.
 * Description: 文件 File 类方法的练习4，删除文件
 */
public class Demo4 {
    public static void main(String[] args) throws IOException {
        File file = new File("test.txt");
        System.out.println(file.exists());
        System.out.println("删除文件");
        System.out.println(file.delete());
        System.out.println("删除文件成功");
    }
}
